package com.arcvideo.acsplayer.ui;

import android.app.Activity;
import android.content.Intent;
import android.os.Bundle;
import android.os.Handler;
import android.util.Log;

import com.arcvideo.acsplayer.R;

public class SplashActivity extends Activity {

	private Handler mHandler = null;
	private static final String LOG_TAG = "SplashActivity";
	Runnable mLoading = new Runnable() {

		@Override
		public void run() {
			startActivity();
		}
	};

	@Override
	public void onCreate(Bundle savedInstanceState) {
		Log.i(LOG_TAG, "Into SplashActivity.onCreate");
		super.onCreate(savedInstanceState);

		setContentView(R.layout.activity_splash);
		mHandler = new Handler();
		mHandler.postDelayed(mLoading, 1000);
		Log.i(LOG_TAG, "Out SplashActivity.onCreate");
	}

	@Override
	protected void onResume() {
		Log.i(LOG_TAG, "SplashActivity onResume");
		super.onResume();
	}

	@Override
	protected void onPause() {
		Log.i(LOG_TAG, "SplashScreen onPause");
		super.onPause();
	}

	@Override
	protected void onDestroy() {
		Log.i(LOG_TAG, "SplashScreen onDestroy");
		super.onDestroy();
	}

	private void startActivity() {
		Log.i(LOG_TAG, "SplashScreen Start LoginActivity");
		Intent displayIntent = new Intent(SplashActivity.this,
				SelectVideoActivty.class);
		startActivity(displayIntent);
		finish();
	}

}